package  
{
	import flash.display.*;
	import flash.events.*;
	import vehicle.*;
	
	public final class ArriveTest extends Sprite 
	{
		
		public function ArriveTest() 
		{
			m_vehicle = new SteeredVehicle();
			m_vehicle.edgeBehavior = Vechicle.WRAP;
			m_vehicle.x = Math.random() * this.stage.stageWidth;
			m_vehicle.y = Math.random() * this.stage.stageHeight;
			this.addChild(m_vehicle);
			
			this.addEventListener(Event.ENTER_FRAME, onEnterFrameHandler);
		}
		
		private function onEnterFrameHandler(evt : Event) : void
		{
			m_vehicle.arrive(new Vector2D(this.mouseX, this.mouseY));
			m_vehicle.update();
		}
		
		private var m_vehicle : SteeredVehicle = null;
	}

}

































///////////////////////////////////////////////////////////////////////////////////////////////////
// end file